﻿package  {
	
	import flash.display.MovieClip;
	import flash.display.Loader;
	import flash.net.URLRequest;
	import Common.GameDefine;
	
	
	public class Loading extends MovieClip 
	{
		public var loader:Loader = null;
		
		public function Loading() 
		{
			// constructor code
			desText.text = "加载基础库";
			
			loader = new Loader()
			imgMc.addChild( loader );
			loader.load( new URLRequest( GameDefine.url + "loading.jpg" ) );
		}
		
		public function setText( des:String , per:int ):void
		{
			
			perText.text = per.toString() + "%";
			
			if ( des )
				desText.text = des;
		}
		
	}
	
}
